package com.geccocrawler.gecco.demo.shijiazhuang;

import com.geccocrawler.gecco.annotation.Gecco;
import com.geccocrawler.gecco.annotation.JSONPath;
import com.geccocrawler.gecco.annotation.Request;
import com.geccocrawler.gecco.annotation.RequestParameter;
import com.geccocrawler.gecco.request.HttpRequest;
import com.geccocrawler.gecco.spider.JsonBean;
import lombok.Getter;
import lombok.Setter;

import java.util.List;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: weixiaohu
 * Date: 2019/6/3
 * Time: 14:16
 */
@Getter
@Setter
@Gecco(
        matchUrl="http://www.sjz12333.gov.cn/si/pages/zcore/zajax.jsp?page={type}&n={page}&size={size}&name1=&name2=&name3=&value1=&value2=&value3=&_={currentTime}",
pipelines = {"sjzPipeline","consolePipeline"})
public class Results implements JsonBean {
    @Request
    private HttpRequest request;
    @RequestParameter
    private int page;
    @RequestParameter
    private int size;
    @RequestParameter
    private long currentTime;
    @RequestParameter
    private String type;
    @JSONPath("$.resultArray")
    private List<Item> list;
    @JSONPath("$.count")
    private int total;
}
